package com.jungle.sp.daily.feature.d9_scope_value;

/**
 * @author Jungle
 * @create 2024-07-14 10:18
 */
public class Demo {
    public static final ScopedValue<String> NAME = ScopedValue.newInstance();

    public static void main(String[] args) {
        ScopedValue.runWhere(NAME,"杨紫",Demo::run1);
    }

    public static void run1() {
        System.out.println(STR."run1==>\{NAME.get()}");
        ScopedValue.runWhere(NAME,"李白",Demo::run2);
        run2();


    }


    public static void run2() {
        System.out.println(STR."run2==>\{NAME.get()}");
    }
}
